<%--
  Created by IntelliJ IDEA.
  User: Administrator
  Date: 2021/7/23
  Time: 8:48
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title></title>
    <link rel="stylesheet" type="text/css" href="../../css/reset.css"/>
    <link rel="stylesheet" type="text/css" href="../../css/list.css"/>
    <link rel="stylesheet" type="text/css" href="../../css/dist_bootstrap-table.css"/>
    <link rel="stylesheet" type="text/css" href="../../css/bootstrap.css">
    <script src="../../js/jquery-1.11.1.js"></script>
    <script src="../../js/bootstrap.js"></script>
    <script src="../../js/dist_bootstrap-table.js"></script>
    <script src="../../js/dist_locale_bootstrap-table-zh-CN.js"></script>
</head>
<body>

<table id="table"></table>
<script>
    $('#table').bootstrapTable({
        url: '/delivery/list.do',
        theadClasses:'',
        classes: 'table table-bordered  table-dark table-striped',
        pageSize: 15,
        pageList: [2,5,10, 20, 50],
        autoRefresh: 'fa-clock',
        autoRefreshInterval: '5',
        search: true,
        pagination: true,
        showExtendedPagination:true,
        showButtonIcons:true,
        trimOnSearch:true,
        detailViewIcon:true,
        showRefresh:true,
        smartDisplay:true,
        showToggle:true,
        responseHandler: function (res) {
            console.log(res)
            return eval(res.dataList);
        },
        queryParams:function(params){
            var temp = {
                offset:params.offset,
                pageNumber:params.limit
            };
            return temp;
        },
        columns: [
            {
                title: '快件编号',
                field: "deliveryId",
                sortable: true
            },
            {
                title: '取件码',
                field: "deliveryCode",
                sortable: true
            },
            {
                title: '快件公司',
                field: "deliveryCompany",
                sortable: true
            },
            {
                title: '收件人',
                field: "deliveryAcceptor",
                sortable: true
            },
            {
                title: '收件人电话',
                field: "acceptorPhone",
                sortable: true
            },
            {
                title: '快递单号',
                field: "deliveryNum",
                sortable: true
            },
            {
                title: '快件状态',
                field: "deliveryState",
                sortable: true
            },
            {
                title: '状态变化时间',
                field: "stateChangeTime",
                sortable: true
            }
        ]
    })
</script>
</body>
</html>
